#ifndef __STRING_H__
#define __STRING_H__
#include <string>
#include <vector>

#define GetElementStr(str) str != NULL ? str : ""
class String
{
public:
    String(std::string &str);
public:    
    std::string Sub(int start, int end = -1);
    std::vector<std::string> &GetWords();
    void CleanRN();
private:
    bool IsZhCh(char p);
    bool IsUTF8(const void* pBuffer, long size);
private:
    bool m_isUtf8;
    std::string m_string;
    std::vector<std::string> m_words;
};

#endif

